﻿@{
    ViewBag.Title = "添加";
    Layout = "../Shared/_Layout.cshtml";
}
@using mscook.mvc;
@model mscook.core.domain.Chef
@section JavaScript
{
    <script type="text/javascript" src="@Url.Content("~/scripts/jquery.validate.js")"></script>
    <script type="text/javascript" src="@Url.Content("~/scripts/jquery.validate.unobtrusive.js")"></script>
    <script type="text/javascript" src="@Url.Content("~/scripts/jquery.unobtrusive-ajax.js")"></script>
}
@Html.Partial("_BtnModalLoder")
@Html.Partial("_MultiBtnModalLoder")
<div id="resourceTypeModal" class=" modal hide fade form-horizontal">
</div>
<div id="hotelModal" class=" modal hide fade form-horizontal">
</div>
<div>
    <ul class="breadcrumb">
        <li>
            <a href="@Url.Action("Index")">主页</a> <span class="divider">/</span>
        </li>

    </ul>
</div>
<div class="row-fluid sortable">
    <div class="box span12">
        <div class="box-header well">
            <h2><i class="icon-edit"></i></h2>
            <div class="box-icon">
                <a href="@Url.Action("Add")" class="btn btn-setting btn-round"><i class="icon-plus-sign"></i></a>
            </div>
        </div>

        <div class="box-content">
            @using (Html.BeginForm("Add", "chef", FormMethod.Post, new { enctype = "multipart/form-data", @class = "form-horizontal" }))
            {
                <fieldset>
                    <legend>厨师增加</legend>
                    <div class="control-group">
                        <label class="control-label">厨师名</label>
                        <div class="controls">
                            <div class="input-prepend">
                                @Html.TextBoxFor(chef => chef.Name, new { size = "16" })
                            </div>
                            @Html.ValidationMessageFor(chef => chef.Name)
                        </div>
                    </div>
                    <div class="control-group">
                        <label class="control-label">职位</label>
                        <div class="controls">
                            <div class="input-prepend">
                                @Html.TextBoxFor(chef => chef.Position, new { size = "16" })
                            </div>
                            @Html.ValidationMessageFor(chef => chef.Position)
                        </div>
                    </div>
                    <div class="control-group">
                        <label class="control-label">地区</label>
                        <div class="controls">
                            <div class="input-prepend">
                                @Html.TextBoxFor(chef => chef.Address, new { size = "16" })
                            </div>
                            @Html.ValidationMessageFor(chef => chef.Address)
                        </div>
                    </div>
                    <div class="control-group">
                        <label class="control-label">置顶</label>
                        <div class="controls">
                            <div class="input-prepend">

                                <select id="IsTop" name="IsTop">
                                    <option value="false" selected="selected">否</option>
                                    <option value="true">是</option>
                                </select>

                            </div>

                        </div>
                    </div>

                    <div class="control-group">
                        <label class="control-label">责任编辑</label>
                        <div class="controls">
                            <div class="input-prepend">
                                @Html.TextBoxFor(chef => chef.Editor, new { size = "16" })
                            </div>
                            @Html.ValidationMessageFor(chef => chef.Editor)
                        </div>
                    </div>

                    <div class="control-group">
                        <label class="control-label">简介</label>
                        <div class="controls">
                            <div class="input-prepend">
                                @Html.TextAreaFor(chef => chef.Summary, new { rows = "10", size = "16", @class = "cleditor" })
                            </div>
                            @Html.ValidationMessageFor(chef => chef.Summary)
                        </div>
                    </div>

                    <div class="control-group">
                        <label class="control-label">类型</label>
                        <div class="controls">
                            <div class="input-prepend">
                                @Html.TextBox("ChefTypeName", "", new { @readonly = "true" })
                                @Html.Hidden("ChefTypeId")
                            </div>
                            <button id="resourceTypeModalBtn" type="button" class="btn btn-primary multimodalLoder" data-num="1" data-link-name="ChefTypeName" data-link-id="ChefTypeId" data-link-modal="resourceTypeModal" data-type="Chef" data-url="/weblogin/resourcetype/MultiResourceTypeModal"><i class="icon-edit icon-white"></i></button>
                        </div>
                    </div>



                    <div class="control-group">
                        <label class="control-label">酒店</label>
                        <div class="controls">
                            <div class="input-prepend">
                                <input id="HotelId" name="HotelId" type="hidden" />
                                <input id="HotelName" name="HotelName" type="text" readonly="true" />

                            </div>

                            <button id="hotelModalBtn" type="button" class="btn btn-primary modalLoder" data-num="1" data-link-name="HotelName" data-link-id="HotelId" data-link-modal="hotelModal" data-url="/weblogin/hotel/hotelModal"><i class="icon-edit icon-white"></i></button>

                        </div>
                    </div>



                    <div class="control-group">
                        <label class="control-label">图片上传</label>
                        <div class="controls">
                            <div class="fileupload fileupload-new" data-provides="fileupload">
                                <span class="btn btn-file">
                                    <span class="fileupload-new">请选择图片</span>
                                    <span class="fileupload-exists">更改图片</span>
                                    <input name="related_content_image[0]" type="file" />
                                </span>
                                <span class="fileupload-preview"></span>
                                <a href="#" class="close fileupload-exists" data-dismiss="fileupload" style="float: none">×</a>
                            </div>
                        </div>
                    </div>
                    <div class="form-actions">
                        <button type="submit" class="btn btn-primary btn-large">保存</button>
                        <button class="btn btn-large">Cancel</button>
                    </div>
                </fieldset>
            }
        </div>
    </div>
    <!--/span-->

</div>
